const http = require('../utils/http.js');

// 添加购物车
const addCart = (data) => {
    return http.request('POST', `/Cart`, data)
}

// 编辑购物车
const editCart = (data) => {
    return http.request('PUT', `/Cart`, data)
}

// 删除购物车
const deleteCart = (data) => {
    return http.request('DELETE', '/Cart', data)
}
// 购物车列表
const getCartList = (data) => {
    return http.request('POST', `/Cart/page`, data)
}

module.exports = {
    addCart,
    editCart,
    deleteCart,
    getCartList
}